oracle.pg.nosql.index.lucene

## Class NoSQLLuceneVertexAutoIndex

- java.lang.Object
- - oracle.pg.text.lucene.LuceneIndex<T>
  - - oracle.pg.text.lucene.LuceneAutoIndex<Vertex>
    - - oracle.pg.text.lucene.LuceneVertexAutoIndex
      - - oracle.pg.nosql.index.lucene.NoSQLLuceneVertexAutoIndex

- All Implemented Interfaces:
    Index<Vertex>, OracleAutoIndex<Vertex>, OracleIndex<Vertex>

      public class NoSQLLuceneVertexAutoIndex
      extends LuceneVertexAutoIndex

  This class extends LuceneVertexAutoIndex to handle an automatic index on Vertex objects over an Oracle NoSQL Database backend

- - ### Field Summary

    - ### Fields inherited from interface oracle.pg.text.OracleIndex

      `EDGE_ID_PROP, EDGE_LABEL_PROP, END_NODE_ID_PROP, START_NODE_ID_PROP, TYPE_DT_BOOL, TYPE_DT_DATE, TYPE_DT_DOUBLE, TYPE_DT_FLOAT, TYPE_DT_INTEGER, TYPE_DT_SERIALIZABLE, TYPE_DT_STRING, VERTEX_ID_PROP`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `NoSQLLuceneVertexAutoIndex(String indexName, OraclePropertyGraph oraclePropertyGraph, Parameter<String,Object>[] indexParameters, boolean erase)` Constructs a new NoSQLLuceneVertexAutoIndex object.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `closeConnectionsArray()` Closes the connection array.
    `Object[]` | `getConnectionsArray()` Gets the connection array.
    `Iterable<Vertex>[]` | `getElementsFromPG(String[] keys, Object[] connArray, int iStartSplitId)` Gets an Iterable<Vertex> of vertices from the associated property graph, matching the specified keys.
    `int` | `getPartitionsNumber()` Gets the number of partitions of the vertex table for the associated property graph.

    - ### Methods inherited from class oracle.pg.text.lucene.LuceneVertexAutoIndex

      `get, getDocIdentifier, getElementsFromPG, getElementsFromPG, getElementsFromPG, getPartitioned`

    - ### Methods inherited from class oracle.pg.text.lucene.LuceneAutoIndex

      `close, containsIndexedKey, getIndexedKeys, indexElements, indexElementsPartitioned, loadIndexedKeys, put, put, reindexElements, reindexElements, reindexElements, reindexElementsNoPartitioned, reindexElementsPartitioned, reindexElementsPartitioned, reindexElementsPartitioned`

    - ### Methods inherited from class oracle.pg.text.lucene.LuceneIndex

      `add, addToDeleteCache, buildSearchTerm, buildSearchTerm, clearIndex, commit, count, count, count, deleteExistingDirectories, dropIndex, get, get, getDirectory, getDirectoryName, getGraphName, getIndexClass, getIndexName, getIndexParameters, getOracleDirectory, getOracleIndexParameters, getOracleSearcherManager, getParameters, getPartitioned, getSearcherFactory, getTotalShards, isAutoIndex, isDelBatchEmpty, isDelBatchFull, isUpdatesBatchEmpty, isUpdatesBatchFull, query, query, remove, remove, remove, remove, removeAll, removeAll`

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface oracle.pg.text.OracleAutoIndex

      `containsIndexedKey, get, getIndexedKeys, indexElements, indexElementsPartitioned, loadIndexedKeys, reindexElements, reindexElements, reindexElements, reindexElementsNoPartitioned, reindexElementsPartitioned, reindexElementsPartitioned, reindexElementsPartitioned`

    - ### Methods inherited from interface oracle.pg.text.OracleIndex

      `add, buildSearchTerm, buildSearchTerm, clearIndex, close, commit, count, count, dropIndex, getDirectoryName, getGraphName, getIndexClass, getOracleIndexParameters, getParameters, getPartitioned, getTotalShards, isDelBatchEmpty, isDelBatchFull, isUpdatesBatchEmpty, isUpdatesBatchFull, query, refreshIndex, remove, removeAll`

    - ### Methods inherited from interface com.tinkerpop.blueprints.Index

      `count, get, getIndexName, put, query, remove`

- - ### Constructor Detail

    - #### NoSQLLuceneVertexAutoIndex

          public NoSQLLuceneVertexAutoIndex(String indexName,
                                    OraclePropertyGraph oraclePropertyGraph,
                                    Parameter<String,Object>[] indexParameters,
                                    boolean erase)

      Constructs a new NoSQLLuceneVertexAutoIndex object.
      Parameters:
        `indexName` - the name of the index
        `oraclePropertyGraph` - an `OraclePropertyGraph` object.
        `indexParameters` - a collection of parameters for the underlying index implementation.
        `erase` - a boolean specifying if the index should be cleared at the beginning.

  - ### Method Detail

    - #### closeConnectionsArray

          public void closeConnectionsArray()

      Closes the connection array.
      Specified by:
        `closeConnectionsArray` in interface `OracleAutoIndex<Vertex>`
      Specified by:
        `closeConnectionsArray` in class `LuceneAutoIndex<Vertex>`

    - #### getConnectionsArray

          public Object[] getConnectionsArray()
                                       throws IOException

      Gets the connection array.
      Specified by:
        `getConnectionsArray` in interface `OracleAutoIndex<Vertex>`
      Specified by:
        `getConnectionsArray` in class `LuceneAutoIndex<Vertex>`
      Returns:
        an array of Connection objects
      Throws:
        `IOException`

    - #### getElementsFromPG

          public Iterable<Vertex>[] getElementsFromPG(String[] keys,
                                             Object[] connArray,
                                             int iStartSplitId)

      Gets an Iterable<Vertex> of vertices from the associated property graph, matching the specified keys.
      Specified by:
        `getElementsFromPG` in interface `OracleAutoIndex<Vertex>`
      Specified by:
        `getElementsFromPG` in class `LuceneAutoIndex<Vertex>`
      Parameters:
        `keys` - an array of the keys to be queried over the property graph.
        `connArray` - a `Connection` array used for concurrent querying inside the Oracle property graph. Each element of this array must be an instance of KVStoreConfig
        `iStartSplitId` - the starting split used for querying.
      Returns:
        an Iterable<Vertex> object.

    - #### getPartitionsNumber

          public int getPartitionsNumber()

      Gets the number of partitions of the vertex table for the associated property graph.
      Specified by:
        `getPartitionsNumber` in interface `OracleAutoIndex<Vertex>`
      Specified by:
        `getPartitionsNumber` in class `LuceneAutoIndex<Vertex>`
      Returns:
        the number of partitions of the element's table.

Copyright © 2015 Oracle and/or its afflilates. All Rights Reserved.